This invention relates to the allocation of optimal quantization bit numbers to a plurality of frequency band or subband signals of an input signal. Such optimal quantization bit number allocation is indispensable for encoding the input signal into an encoded signal for transmission to a receiving side through a transmission channel at a certain bit rate.
In a manner which will later be described in greater detail, optimal quantization bit numbers are allocated or assigned to an input signal which is typically an audio input signal. More particularly, the optimal quantization bit numbers are allocated to the first through I-th frequency band signals B(1) to B(I) of the input signal and in accordance with the frequency bands of the input signal. Each frequency band signal B(i) (i being a variable between 1 and I, both inclusive of an input signal) is assigned quantization bits of an optimal quantization bit number which is specific to the frequency band signal under consideration. The optimal quantization bit number may be equal to zero depending on the frequency band signal in question.
It may be noted here that it is possible to preliminarily calculate a maximal quantization bit number which is individually allocatable to the frequency band signals B (suffixes omitted). Similarly, it is possible to calculate a total of quantization bit numbers allocatable to the frequency band signals. The total of quantization bit numbers depends on the bit rate at which the quantization bits representative of the frequency band signals are transmitted. Before being quantized into the quantization bits of the optimal quantization bit numbers, the frequency band signals are sampled at a preselected sampling rate. The total of quantization bit numbers depends furthermore on the sampling rate.
In each of the frequency bands, the frequency band signal has a maximal signal level and a mask level. The encoded signal is accompanied by quantization noise, which depends on the frequency bands and may be referred to simply as noise.
First, attention is directed to each of the frequency band signals. A signal to mask ratio (SMR), namely, a ratio of the maximal signal level to the mask level, is calculated. A mask to noise ratio (MNR) is calculated by subtracting the signal to mask ratio from a signal to noise ratio (SNR).
Next, all available frequency band or subband signals are taken into consideration. A minimum of the mask to noise ratios of the available subband signals is searched for. A subband signal Bmin, that has the minimal mask to noise ratio is selected from one of the available subband signals.
Subsequently, a temporary quantization bit number Na is allocated to the selected subband signal. The temporary quantization bit number Na is compared to the maximal quantization bit number Nmax which is allocatable to the selected subband signal. The maximal quantization bit number Nmax is preliminarily calculated. If the temporary quantization bit number Na is less than the maximal quantization bit number Nmax, Then temporary quantization bit number Na is incremented by one. In this manner, an already allocated quantization bit number is assigned to the selected subband signal.
A sum of such already allocated quantization bit numbers is calculated in connection with the available subband signals and is compared to the total of quantization bit numbers. The total of quantization bit numbers is preliminarily calculated as regards the quantization bit numbers allocatable to the frequency band signals. If the sum of the already calculated bit numbers is less than the total of quantization bit numbers, then the above-described steps are repeated in loops with the temporary quantization bit number compared to the maximal quantization bit number in each loop.
When the temporary quantization bit number reaches the maximal quantization bit number in a particular loop, the selected subband signal is excluded from the available subband signals to leave one less remaining new available subband signal than the number of available subband signals used in the particular loop. A new subband signal having a minimum mask to noise ratio is selected from the new available subband signals. The loops are repeated for the new selected subband signal and the new available subband signals.
In this manner, the loops are iterated until the sum of already allocated quantization bit numbers becomes equal to the total of quantization bit numbers. The optimal quantization bit numbers are eventually allocated to the frequency band signals.
According to a conventional quantization bit number allocation method, the loops must be iterated a plurality of times and are substantially equal in number to the total of the quantization bit numbers allocatable to the frequency band signals. As a consequence, a very long computer processing time has been necessary to allocate the optimal quantization bit numbers to the frequency band signals. A long computer processing time has been necessary when dealing with the high efficiency encoding of an input signal into an encoded signal of the optimal quantization bit numbers of a total of quantization bit numbers is increased in compliance with an increased rate.